package com.example.student.service;

import com.example.student.bean.Emp;
import com.example.student.mapper.EmpMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;
@Service
public class EmpServiceImpl implements EmpService{
    @Resource
    private EmpMapper empMapper;
    @Override
    public List<Map<String, Object>> queryAll() {
        return empMapper.queryAll();
    }

    @Override
    public int addEmp(Emp emp) {
        return empMapper.addEmp(emp);
    }

    @Override
    public int del(String id) {
        return empMapper.del(id);
    }

    @Override
    public Emp queryById(String id) {
        return empMapper.queryById(id);
    }

    @Override
    public int update(Emp emp) {
        return empMapper.update(emp);
    }
}
